package com.yc.shadowdemo.demo

import com.yc.commontlib.YcJetpack
import com.yc.shadowdemo.App
import retrofit2.http.GET
import retrofit2.http.Header
import retrofit2.http.Query

/**
 * Creator: yc
 * Date: 2021/6/3 15:21
 * UseDes:
 */
interface ApiService {
    /**
     * 登录
     */
    @GET("admin/api/auth/token?")
    suspend fun login(
        @Query("account") account: String,
        @Query("password") password: String,
        @Query("clientId") clientId: String = "1",
    ): String

    /**
     * 版本更新
     */
    @GET("clientPackage/getClientVersion")
    suspend fun getVersion(
        @Query("clientType") clientType: String = "1",
        @Query("channel") channel: String = App.mInstant.packageName,
        @Header(YcJetpack.OTHER_BASE_URL) otherUrl: String = UrlHelper.URL_VERSION,
    ): String
}